<%--                                                                       --%>
<%-- Copyright (c) 2001-2006 BroadVision, Inc.  All rights reserved.       --%>
<%--                                                                       --%>
<%-- This software is copyrighted. Under the copyright laws, this software --%>
<%-- may not be copied, in whole or in part, without prior written consent --%>
<%-- of BroadVision, Inc. or its assignees. This software is provided      --%>
<%-- under the terms of a license between BroadVision and the recipient,   --%>
<%-- and its use is subject to the terms of that license.                  --%>
<%--                                                                       --%>
<%-- This software may be protected by one or more U.S. and International  --%>
<%-- patents.  Certain applications of BroadVision One-To-One software are --%>
<%-- covered by U.S. patent 5,710,887.                                     --%>
<%--                                                                       --%>
<%-- TRADEMARKS: BroadVision and BroadVision One-To-One are registered     --%>
<%-- trademarks of BroadVision, Inc., in the United States and the         --%>
<%-- European Community, and are trademarks of BroadVision, Inc., in other --%>
<%-- countries.  The BroadVision logo, is a trademark of BroadVision,      --%>
<%-- Inc., in the United States and other countries. Additionally, IONA    --%>
<%-- and Orbix are trademarks of IONA Technologies, Ltd.  RSA, MD5, and    --%>
<%-- RC2 are trademarks of RSA Data Security, Inc.                         --%>
<%--                                                                       --%>

<!DOCTYPE html 
  PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<%@ taglib uri="/WEB-INF/c.tld" prefix="c" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html-el.tld" prefix="html-el" %>
<%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %>

<%@ page import = "java.util.HashMap" %>

<script language="javascript" src="<%= request.getContextPath() %>/cs/js/stringFunc.js" type="text/javascript">
</script>

<script language=JavaScript>
<!--
function startMicrositeSearch(theForm) {
  var qStr1 = stringTrim(theForm.queryString1.value);
  
  if (qStr1 == null || qStr1.length == 0) {
    alert('<bean:message key="ep.search.empty.criteria"/>');
    return false;
  }
  
  theForm.submit();
  return true;
}

function submitViaEnter(evt) {
    evt = (evt) ? evt : event;
    var target = (evt.target) ? evt.target : evt.srcElement;
    var form = target.form;
    var charCode = (evt.charCode) ? evt.charCode :
        ((evt.which) ? evt.which : evt.keyCode);
    if (charCode == 13 || charCode == 3) {
        return startMicrositeSearch(form);
    }
    return true;
}

// -->
</script>

<jsp:useBean id="micrositeInfo" scope="request" class="java.util.HashMap"/>

<c:url var="basicUrl" value="/cs/micrositeBasicSearch.do"/>

<form name="basicSearch" onsubmit="return false;" action='<c:out value="${basicUrl}"/>' method="get">
  <input type="hidden" name="searchType" value="0"/>  

  <div class="menuBlocktitle">
    <span>

    <c:if test="${!empty param.micrositeId}">  
        <input type="hidden" name="isInMicrosite" value="true"/>
        <input type="hidden" name="micrositeId" value='<c:out value="${param.micrositeId}"/>' />
        <input type="hidden" name="displayPhaseId" value='<c:out value="${param.displayPhaseId}"/>' />
        <bean:message key="ep.search.searchMicrosite"/>
    </c:if>
    </span>
	</div>
	
	<div class="menuBlockWrap"> 	
    <input type="text" name="queryString1" onkeypress="return submitViaEnter(event);" size="25" maxlength="50" />
    <input type="button" class="titleButton" name="goBtn" onclick="return startMicrositeSearch(this.form);" 
           value='<bean:message key="button.go"/>' />
              
	<br><br>
  
  <c:url var="extendedUrl" value="/cs/micrositeExtendedSearch.do">
    <c:if test="${!empty param.micrositeId}">
      <c:param name="micrositeId" value="${param.micrositeId}"/>
      <c:param name="displayPhaseId" value="${param.displayPhaseId}"/>
    </c:if>
  </c:url>

  <a href='<c:out value="${extendedUrl}"/>'><bean:message key="ep.search.advancedSearch"/>
  </a>

    	</div>
    
</form>


